package com.yc.demo;

import com.mysql.jdbc.Driver;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;

import javax.servlet.Servlet;

@Configuration
@ComponentScan("com.yc.demo")
// 前置条件
@ConditionalOnProperty(prefix = "demo", name = "enable")
@ConditionalOnClass({Servlet.class, Driver.class})
public class DemoAutoConfiguration {
}
